package com.letoken.platform.repo.admin.dao;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.letoken.platform.repo.admin.po.Withdraw;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.letoken.platform.repo.admin.req.user.QueryAppWithdrawAuditListReq;
import com.letoken.platform.repo.admin.req.user.QueryAppWithdrawListReq;
import com.letoken.platform.repo.admin.req.user.QueryLineChartReq;
import com.letoken.platform.repo.admin.res.user.*;
import org.apache.ibatis.annotations.Param;

import java.util.HashSet;
import java.util.List;

/**
 * <p>
 * Le账户-用户钱包提现记录 Mapper 接口
 * </p>
 *
 * @author 作者
 * @since 2022-12-12
 */
public interface WithdrawMapper extends BaseMapper<Withdraw> {

    Page<QueryAppWithdrawListRes> queryWithdrawList(@Param("page") Page<QueryAppWithdrawListRes> page, @Param("req") QueryAppWithdrawListReq req);

    Page<QueryAppWithdrawAuditListRes> QueryAppWithdrawAuditListReq(@Param("page") Page<QueryAppWithdrawAuditListRes> page, @Param("req") QueryAppWithdrawAuditListReq req);

    int updateErrorResponse(@Param("id") long id, @Param("response") String response);

    List<Integer> queryUserBytoUser(@Param("toId") Integer toId);

    QueryWithdrawCountRes queryWithdrawCount();

    List<QueryLineChartRes> queryWithdrawLineChart(@Param("req") QueryLineChartReq req);

    List<QueryAppAssetsSumRes> queryUserAssetsSum();

    List<QueryAppUserTokenAilableBalanceRes> queryUserAvailableBalance(Integer userId);

    HashSet<String> existSNList(@Param("userId") Integer userId, @Param("snList") List<String> snList);


}
